<template>
	<view class="agreement-confirm-main-box">
		<view class="agreement-confirm-box">
			<view class="title">用户协议及隐私保护</view>
			<view class="content">
				已阅读并同意
				<!-- <text class="tip" @click="gotoWebUrl('https://passport.ximalaya.com/page/privacy_policy')">《隐私信息保护政策》</text> -->
				<text class="tip" @click="showAgreementHandler(1)">《隐私保护指引》</text>
				<text class="tip" @click="showAgreementHandler(2)">《产品说明》</text>
				等内容
			</view>

			<view class="submit-btn" @click="okHandler">同意并办理</view>
			<view class="cancel-btn" @click="cancelHandler">不同意</view>
		</view>
	</view>
</template>
<script>
	export default {
		methods: {
			showAgreementHandler(value) {
				this.$emit('showAgreement', value)
			},
			gotoWebUrl(pagePath) {
				window.location.href = pagePath
			},
			okHandler() {
				this.$emit('ok')
			},
			cancelHandler() {
				this.$emit('cancel')
			}
		}
	}
</script>

<style lang="scss" scoped>
	.agreement-confirm-main-box {
		position: fixed;
		left: 0;
		top: 0;
		width: 100vw;
		height: 100vh;
		display: flex;
		justify-content: center;
		align-items: center;
		background: url("https://qiming-1308147483.cos.ap-chengdu.myqcloud.com/doc%2Fpinzhi_shenghuo_huiyuan_quanyi%2Fcommon%2Flogin-shadow-bg.png") repeat;
		z-index: 2;

		.agreement-confirm-box {
			border-radius: 20rpx;
			background-color: #faf7f2;
			padding: 30rpx;
			width: 80%;
			box-sizing: border-box;
			padding: 63rpx 58rpx 38rpx;

			.title {
				font-size: 36rpx;
				font-family: PingFang SC;
				font-weight: bold;
				color: #000000;
				text-align: center;
			}

			.content {
				font-size: 28rpx;
				font-family: Source Han Sans CN;
				color: #000000;
				text-align: justify;
				margin-top: 61rpx;
				line-height: 45rpx;

				.tip {
					color: #DB202D;
				}

			}

			.submit-btn {
				height: 110rpx;
				// line-height: 110rpx;
				background: #51C78B;
				border-radius: 55rpx;
				margin-top: 52rpx;
				font-size: 32rpx;
				font-family: PingFang SC;
				font-weight: bold;
				color: #FFFFFF;
				text-align: center;
				display: flex;
				justify-content: center;
				align-items: center;
			}

			.cancel-btn {
				text-align: center;
				margin-top: 36rpx;
				font-size: 24rpx;
				font-family: PingFang SC;
				font-weight: 500;
				color: #999999;
			}
		}
	}
</style>